<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <title><?=$str['alias']?></title>

</head>
<body style="padding:0;margin:0;" id="bdIframe">
<div id="app">
    <div v-show="type">
        <object data="<?=$str['address']?>" :width="webwidth" :height="webheight">
            <embed src="<?=$str['address']?>" :width="webwidth" :height="webheight" /></embed>
        </object>
    </div>
</div>
</body>
<script>
    const app = new Vue({
        data () {
            return {
                webwidth:"",
                webheight:"",
                url:"",
                type: false
            }
        },
        methods: {
            refit:function(){
                oIframe = document.getElementById('bdIframe');
                deviceWidth = document.documentElement.clientWidth;
                deviceHeight = document.documentElement.clientHeight;
                this.webwidth = (Number(deviceWidth)) + 'px'; //oIframe.style.width =
                this.webheight = (Number(deviceHeight)) + 'px';//= oIframe.style.height =
                console.log(this.webwidth)
            }
        },
        mounted () {
            this.refit();
            <?php if ($str['code']==1 && $str['type']==1) {?>
            this.type = true;
            this.url = "<?=$str['address']?>"
            <?php }else{ ?>
            alert('您已到期，请续费');
            <?php } ?>
        }
    }).$mount('#app');
</script>
</html>